package dynamic.metadata.property;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.FieldStrategy;
import org.apache.ibatis.type.JdbcType;
import org.apache.ibatis.type.TypeHandler;
import org.apache.ibatis.type.UnknownTypeHandler;

public class TableField {

    String value = "";

    boolean exist = true;

    String condition = "";

    String update = "";

    FieldStrategy insertStrategy = FieldStrategy.DEFAULT;

    FieldStrategy updateStrategy = FieldStrategy.DEFAULT;

    FieldStrategy whereStrategy = FieldStrategy.DEFAULT;

    FieldFill fill = FieldFill.DEFAULT;

    boolean select = true;

    boolean keepGlobalFormat = false;

    String property = "";

    JdbcType jdbcType = JdbcType.UNDEFINED;

    Class<? extends TypeHandler> typeHandler = UnknownTypeHandler .class;

    boolean javaType = false;

    String numericScale = "";

    public String value() {
        return value;
    }

    public void value(String value) {
        this.value = value;
    }

    public boolean exist() {
        return exist;
    }

    public void exist(boolean exist) {
        this.exist = exist;
    }

    public String condition() {
        return condition;
    }

    public void condition(String condition) {
        this.condition = condition;
    }

    public String update() {
        return update;
    }

    public void update(String update) {
        this.update = update;
    }

    public FieldStrategy insertStrategy() {
        return insertStrategy;
    }

    public void insertStrategy(FieldStrategy insertStrategy) {
        this.insertStrategy = insertStrategy;
    }

    public FieldStrategy updateStrategy() {
        return updateStrategy;
    }

    public void updateStrategy(FieldStrategy updateStrategy) {
        this.updateStrategy = updateStrategy;
    }

    public FieldStrategy whereStrategy() {
        return whereStrategy;
    }

    public void whereStrategy(FieldStrategy whereStrategy) {
        this.whereStrategy = whereStrategy;
    }

    public FieldFill fill() {
        return fill;
    }

    public void fill(FieldFill fill) {
        this.fill = fill;
    }

    public boolean select() {
        return select;
    }

    public void select(boolean select) {
        this.select = select;
    }

    public boolean keepGlobalFormat() {
        return keepGlobalFormat;
    }

    public void KeepGlobalFormat(boolean keepGlobalFormat) {
        this.keepGlobalFormat = keepGlobalFormat;
    }

    public String property() {
        return property;
    }

    public void property(String property) {
        this.property = property;
    }

    public JdbcType jdbcType() {
        return jdbcType;
    }

    public void JdbcType(JdbcType jdbcType) {
        this.jdbcType = jdbcType;
    }

    public Class<? extends TypeHandler> typeHandler() {
        return typeHandler;
    }

    public void TypeHandler(Class<? extends TypeHandler> typeHandler) {
        this.typeHandler = typeHandler;
    }

    public boolean javaType() {
        return javaType;
    }

    public void javaType(boolean javaType) {
        this.javaType = javaType;
    }

    public String numericScale() {
        return numericScale;
    }

    public void numericScale(String numericScale) {
        this.numericScale = numericScale;
    }
}
